package com.lxk.ai.assistant;

import dev.langchain4j.service.MemoryId;
import dev.langchain4j.service.SystemMessage;
import dev.langchain4j.service.UserMessage;
import dev.langchain4j.service.spring.AiService;
import reactor.core.publisher.Flux;

import static dev.langchain4j.service.spring.AiServiceWiringMode.EXPLICIT;

@AiService(
        wiringMode = EXPLICIT,
//        chatModel = "qwenChatModel", //配置模型
        streamingChatModel = "qwenStreamingChatModel", //配置流式模型
        chatMemoryProvider = "chatMemoryProviderHealthAgent",
        tools = "appointmentTools" ,//tools配置
//        contentRetriever = "contentRetrieverHealthAgent" //配置向量存储
        contentRetriever = "contentRetrieverXiaozhiPincone" //配置向量存储pincone
)
public interface HealthAgent {

    @SystemMessage(fromResource = "healthAgent-prompt-template.txt")
    Flux<String> chat(@MemoryId Long memoryId, @UserMessage String userMessage);
}
